// ---------------------------------------个人中心---------------------------------------
// ---------------------------------------订单预览点击效果---------------------------------------
document.querySelector(".content .content-bd .col-main .recent-order .clearfix .tab-hd").onclick = (function(event){
    var element = event.target
    var colli = document.querySelectorAll(".content .content-bd .col-main .recent-order .clearfix .tab-hd li")
    for(var i = 0;i < colli.length;i++){
         colli[i].className = ""
         console.log(colli[i].className)
       }
       element.className = "afli"

})

// ---------------------------------------订单预览3个状态切换隐藏浏览框---------------------------------------
document.querySelector(".content .content-bd .col-main .recent-order .clearfix .tab-hd #l1").onclick = function(){
  document.querySelector(".content .content-bd .col-main .recent-order .bd").style.display="block"
  document.querySelector(".content .content-bd .col-main .recent-order .bd1").style.display="none"
  document.querySelector(".content .content-bd .col-main .recent-order .bd2").style.display="none"
}

document.querySelector(".content .content-bd .col-main .recent-order .clearfix .tab-hd #l2").onclick = function(){
  document.querySelector(".content .content-bd .col-main .recent-order .bd").style.display="none"
  document.querySelector(".content .content-bd .col-main .recent-order .bd1").style.display="block"
  document.querySelector(".content .content-bd .col-main .recent-order .bd2").style.display="none"
}

document.querySelector(".content .content-bd .col-main .recent-order .clearfix .tab-hd #l3").onclick = function(){
  document.querySelector(".content .content-bd .col-main .recent-order .bd").style.display="none"
  document.querySelector(".content .content-bd .col-main .recent-order .bd1").style.display="none"
  document.querySelector(".content .content-bd .col-main .recent-order .bd2").style.display="block"
}

// ---------------------------------------权益点击悬浮窗---------------------------------------
// 还车券
document.querySelector(".privilege-box .privilege-info .i1").onclick = function(){
  document.querySelector(".float-windows").style.display="block"
  document.querySelector("#f1").style.display="block"
}

document.querySelector(".float-windows #f1 .back").onclick = function(){
  document.querySelector(".float-windows").style.display="none"
  document.querySelector("#f1").style.display="none"
}

// 生日
document.querySelector(".privilege-box .privilege-info .i2").onclick = function(){
  document.querySelector(".float-windows").style.display="block"
  document.querySelector("#f2").style.display="block"
}

document.querySelector(".float-windows #f2 .back").onclick = function(){
  document.querySelector(".float-windows").style.display="none"
  document.querySelector("#f2").style.display="none"
}

// 会员积分
document.querySelector(".privilege-box .privilege-info .i3").onclick = function(){
  document.querySelector(".float-windows").style.display="block"
  document.querySelector("#f3").style.display="block"
}

document.querySelector(".float-windows #f3 .back").onclick = function(){
  document.querySelector(".float-windows").style.display="none"
  document.querySelector("#f3").style.display="none"
}

// 车型升级
document.querySelector(".privilege-box .privilege-info .i4").onclick = function(){
  document.querySelector(".float-windows").style.display="block"
  document.querySelector("#f4").style.display="block"
}

document.querySelector(".float-windows #f4 .back").onclick = function(){
  document.querySelector(".float-windows").style.display="none"
  document.querySelector("#f4").style.display="none"
}

// 免加邮费
document.querySelector(".privilege-box .privilege-info .i5").onclick = function(){
  document.querySelector(".float-windows").style.display="block"
  document.querySelector("#f5").style.display="block"
}

document.querySelector(".float-windows #f5 .back").onclick = function(){
  document.querySelector(".float-windows").style.display="none"
  document.querySelector("#f5").style.display="none"
}

// 延迟还车
document.querySelector(".privilege-box .privilege-info .i6").onclick = function(){
  document.querySelector(".float-windows").style.display="block"
  document.querySelector("#f6").style.display="block"
}

document.querySelector(".float-windows #f6 .back").onclick = function(){
  document.querySelector(".float-windows").style.display="none"
  document.querySelector("#f6").style.display="none"
}

// 邀请
document.querySelector(".privilege-box .privilege-info .i7").onclick = function(){
  document.querySelector(".float-windows").style.display="block"
  document.querySelector("#f7").style.display="block"
}

document.querySelector(".float-windows #f7 .back").onclick = function(){
  document.querySelector(".float-windows").style.display="none"
  document.querySelector("#f7").style.display="none"
}